package com.wangjialu.learner.stream.controller;

import com.wangjialu.learner.stream.service.IMessageProvider;
import com.wangjialu.learner.stream.service.IMessageService;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

/**
 * <p></p>
 *
 * @author WangJialu
 * @since 2021/6/25 0:40
 */
@RestController
public class SendMessageController {

    @Resource
    private IMessageService messageService;
    @Resource
    private IMessageProvider messageProvider;

    @RequestMapping("/sendMessage")
    public String sendMessage() {
        String send = messageService.send();
        return send;
    }

    @RequestMapping("/sendMyMessage")
    public String sendMyMessage() {
        String send = messageProvider.mySend();
        return send;
    }

}
